package com.enjoyor.soa.traffic.util.enums.log;

import com.enjoyor.soa.traffic.util.enums.base.IBasicEnum;

public class LogInfoDic {

	// logclass
	public enum LOG_CLASS_ENUM implements IBasicEnum {

		OPERATOR("LOGCLASS01", "操作"),
		SECURITY("LOGCLASS02", "安全"),
		SYSTEM("LOGCLASS03", "系统"),
		OTHERS("LOGCLASS04", "其他");

		private final String code;
		private final String message;

		LOG_CLASS_ENUM(String code, String message) {
			this.code = code;
			this.message = message;
		}

		@Override
		public String getCode() {
			return this.code;
		}

		@Override
		public String getMessage() {
			return this.message;
		}

	}

	;

	// loglevel
	public enum LOG_LEVEL_ENUM implements IBasicEnum {
		LOG_WARN("LOGLEVEL01", "警告"), LOG_NORMAL("LOGLEVEL02", "一般"), LOG_SERIOUS("LOGLEVEL03", "严重");

		private final String code;
		private final String message;

		LOG_LEVEL_ENUM(String code, String message) {
			this.code = code;
			this.message = message;
		}

		@Override
		public String getCode() {
			return this.code;
		}

		@Override
		public String getMessage() {
			return this.message;
		}
	}

	// transtype
	public enum LOG_TRANSTYPE_ENUM implements IBasicEnum {
		TRANSTYPE_SELECT("DBTRANSTYPESEL", "查询"), TRANSTYPE_INSERT("DBTRANSTYPEADD",
				"增加"), TRANSTYPE_UPDATE("DBTRANSTYPEUPD", "修改"), TRANSTYPE_DELETE("DBTRANSTYPEDEL", "删除"), TRANSTYPE_EXPORT("DBTRANSTYPEEXP", "导出");

		private final String code;
		private final String message;

		LOG_TRANSTYPE_ENUM(String code, String message) {
			this.code = code;
			this.message = message;
		}

		@Override
		public String getCode() {
			return this.code;
		}

		@Override
		public String getMessage() {
			return this.message;
		}
	}

	/**
	 * 根据code获取去value
	 *
	 * @param code
	 * @return
	 */
	public static String getValueByCode(String code) {
		for (LOG_TRANSTYPE_ENUM transtypeEnum : LOG_TRANSTYPE_ENUM.values()) {
			if (transtypeEnum.getCode().equals(code)) {
				return transtypeEnum.getMessage();
			}
		}
		return null;
	}

	// logmodule
	public enum LOG_MODULAR_ENUM implements IBasicEnum {
		/**
		 * TPCMS
		 */
		PROCESS_MANAGEMENT("PROCESSMANAGEMENT", "流程管理模块"),
		PACC_CHECK_MANAGEMENT("PACCCHECKMANAGEMENT", "通行证管理模块"),
		APPLY_REDION_MANAGEMENT("APPLYREDIONMANAGEMENT", "申请区域管理模块"),
		PROHIBITION_LINE_MANAGEMENT("PROHIBITIONLINEMANAGEMENT", "禁行路线管理模块"),
		WHITE_LIST_MANAGEMENT("WHITELISTMANAGEMENT", "白名单管理模块"),
		RELATION_BAYONET_MANAGEMENT("RELATIONBAYONETMANAGEMENT", "关联卡口管理模块"),
		/**
		 * Templat测试
		 */
		TEMPLATE_TEST_MANAGEMENT("TEMPLATETESTMANAGEMENT", "Templat测试模块"),

		/**
		 * TIOM
		 */
		TIOM_SUBSCRIBE_MANAGEMENT("TIOMSUBSCRIBEMANAGEMENT", "关注路段道路管理模块"),

		/**
		 * PSPA预案管理系统
		 */
		PSAS_PRE_PLAN_INFO_MANAGEMENT("PSASPREPLANINFOMANAGEMENT", "预案信息管理模块"),
		PSAS_EMERGENCY_PERSON_MANAGEMENT("PSASEMERGENCYPERSONMANAGEMENT", "应急专员管理模块"),
		PSAS_EMERGENCY_MATERAIL_MANAGEMENT("PSASEMERGENCYMATERAILMANAGEMENT", "应急物资管理模块"),
		PSAS_EMERGENCY_EXPERT_MANAGEMENT("PSASEMERGENCYEXPERTMANAGEMENT", "应急专家管理模块"),
		PSAS_TEMPLATE_INFO_MANAGEMENT("PSASTEMPLATEINFOMANAGEMENT", "文本预案模板管理模块"),
		PSAS_ACT_PLACE_MANAGEMENT("PSASACTPLACEMANAGEMENT", "活动场所管理模块"),
		PSAS_APPENDIX_INFO_MANAGEMENT("PSAS_APPENDIX_INFO_MANAGEMENT", "附件管理模块"),

		/**
		 * TSMS特勤管理系统
		 */
		TSMS_SCHEME_INFO_MANAGEMENT("TSMSSCHEMEINFOMANAGEMENT", "方案管理模块"),
		TSMS_TASK_INFO_MANAGEMENT("TSMSTASKINFOMANAGEMENT", "任务管理模块"),
		TSMS_ROUTE_INFO_MANAGEMENT("TSMSROUTEINFOMANAGEMENT", "线路管理模块"),
		TSMS_ROUTE_POINT_MANAGEMENT("TSMSROUTEPOINTMANAGEMENT", "途径点管理模块"),
		TSMS_RLT_DEVICE_MANAGEMENT("TSMSRLTDEVICEMANAGEMENT", "关联设备管理模块"),
		TSMS_RLT_POST_MANAGEMENT("TSMSRLTPOSTMANAGEMENT", "岗位管理模块"),
		TSMS_POLICE_ASSESS_MANAGEMENT("TSMSPOLICEASSESSMANAGEMENT", "警员考核管理模块"),
		TSMS_EXECUTETASKDISPATCH_MANAGEMENT("TSMSEXECUTETASKDISPATCHMANAGEMENT", "派警管理模块"),
		TSMS_COMMON_PLACE_MANAGEMENT("TSMSCOMMONPLACEMANAGEMENT", "常用单位管理模块"),
		TSMS_COMMON_ROUTE_MANAGEMENT("TSMSCOMMONROUTEMANAGEMENT", "常用线路管理模块"),
		TSMS_POLICE_CALL_NAME_MANAGEMENT("TSMSPOLICECALLNAMEMANAGEMENT", "点名管理模块"),

		/**
		 * MTPS 移动警务
		 */
		MTPS_APPVERSION_MANAGEMENT("MTPSAPPVERSIONMANAGEMENT", "版本更新模块"),
		MTPS_APPMESSAGE_MANAGEMENT("MTPSAPPMESSAGEMANAGEMENT", "消息管理模块"),
		MTPS_APPMENU_MANAGEMENT("MTPSAPPMENUMANAGEMENT", "菜单管理模块"),


		/**
		 * Vms交通诱导发布系统
		 */
		VMS_LED_PUBLISH_MSG_MANAGEMENT("VMS_LED_PUBLISH_MSG_MANAGEMENT", "诱导信息发布模块"),
		VMS_LED_SENDTYPE_RELETE_MANAGEMENT("VMS_LED_SENDTYPE_RELETE_MANAGEMENT", "诱导屏发送策略关联模块"),
		VMS_LED_SENDTYPE_MANAGEMENT("VMS_LED_SENDTYPE_MANAGEMENT", "诱导屏发送策略模块"),
		VMS_LED_POWER_MANAGEMENT("VMS_LED_POWER_MANAGEMENT", "诱导屏开关模块"),
		VMS_LED_GROUP_MANAGEMENT("VMS_LED_GROUP_MANAGEMENT", "诱导屏分组模块"),
		VMS_LED_GROUP_RELETE_MANAGEMENT("VMS_LED_GROUP_RELETE_MANAGEMENT", "诱导屏关联分组模块"),
		VMS_LED_DEPT_RELETE_MANAGEMENT("VMS_LED_DEPT_RELETE_MANAGEMENT", "诱导屏机构关联模块"),
		VMS_LED_BLOCK_CONFIG_MANAGEMENT("VMS_LED_BLOCK_CONFIG_MANAGEMENT", "诱导屏路段配置模块"),
		VMS_PUBLISH_MANAGEMENT("VMS_PUBLISH_MANAGEMENT", "诱导发布模块"),

		/**
		 * efoms设备设施运维管理系统
		 */
		EFOMS_REPAIRS_MANAGEMENT("EFOMS_REPAIRS_MANAGEMENT", "报修管理模块"),
		EFOMS_WORKORDERS_MANAGEMENT("EFOMS_WORKORDERS_MANAGEMENT", "维修管理模块"),
		EFOMS_EVALUATE_MANAGEMENT("EFOMS_EVALUATE_MANAGEMENT", "维修评价模块"),
		EFOMS_CHECK_MANAGEMENT("EFOMS_CHECK_MANAGEMENT", "巡检管理模块"),
		EFOMS_MONITOR_MANAGEMENT("EFOMS_MONITOR_MANAGEMENT", "监测管理模块"),
		EFOMS_WRAN_MANAGEMENT("EFOMS_WRAN_MANAGEMENT", "报警管理模块"),
		EFOMS_ASSENT_MANAGEMENT("EFOMS_ASSENT_MANAGEMENT", "资产管理模块");

		private final String code;
		private final String message;

		LOG_MODULAR_ENUM(String code, String message) {
			this.code = code;
			this.message = message;
		}

		@Override
		public String getCode() {
			return this.code;
		}

		@Override
		public String getMessage() {
			return this.message;
		}
	}


	// operate
	public enum LOG_OPERATE_ENUM implements IBasicEnum {

		SELECT("select", "查询"),INSERT("insert", "新增"), UPDATE("update", "修改"), DELETE("delete", "删除"), EXPORT("export", "导出"),BATCH_INSERT("batchInsert", "批量新增"), BATCH_UPDATE("batchUpdate", "批量修改"), BATCH_DELETE("batchDelete", "批量删除");

		private final String code;
		private final String message;

		LOG_OPERATE_ENUM(String code, String message) {
			this.code = code;
			this.message = message;
		}

		@Override
		public String getCode() {
			return this.code;
		}

		@Override
		public String getMessage() {
			return this.message;
		}
	}


	//
	// system
	public enum LOG_SYSTEM_ENUM implements IBasicEnum {

		TPCMS("TPCMS", "货车禁行系统"), TIOM("TIOM", "综合运行监测系统");

		private final String code;
		private final String message;

		LOG_SYSTEM_ENUM(String code, String message) {
			this.code = code;
			this.message = message;
		}

		@Override
		public String getCode() {
			return this.code;
		}

		@Override
		public String getMessage() {
			return this.message;
		}
	}

	public static void main(String[] args) {
		for (LogInfoDic.LOG_TRANSTYPE_ENUM e : LogInfoDic.LOG_TRANSTYPE_ENUM.values()) {
			System.out.println(e.toString());
		}
	}
}
